<template>
	<view>
		<view class="login">
			<image src="../../static/image/chushi.png"></image>
			<view class="go" @tap="login()">
				<text>微信登录</text>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				
			}
		},
		methods: {
			login(){
				return new Promise((resolve,rejext)=>{
					uni.getUserProfile({
						desc:"必须授权才可以继续使用",
						success:res=>{
							resolve(res.userInfo)
							console.log(res)
						}
					})
				})
				
			}
		}
	}
</script>

<style lang="scss" scoped>
	.login{
		margin-top: 150rpx;
		text-align: center;
		image{
			width: 200rpx;
			height: 200rpx;
		}
		.go{
			margin-top: 80rpx;
			text{
				padding: 20rpx 200rpx;
				background-color: #ee7b2d;
				border-radius: 50rpx;
				color: white;
				font-weight: 800;
			}
		}
	}
</style>
